<ion-view view-title="店员管理" class="employeemanager">
	<ion-nav-bar ng-class="baseclass">
		<ion-nav-back-button></ion-nav-back-button>
	</ion-nav-bar>
	
	<div class="bar bar-subheader padding-0">
		<div class="row top hidboder">
			<div class="col tabtext" data-authname="店员管理" rights-ctrl on-tap="activeTab(0)" ng-class="selectTab==0?'top-activated tabcolor':''">
				店员管理
			</div>
			<div class="col tabtext" data-authname="角色管理" rights-ctrl on-tap="activeTab(1)" ng-class="selectTab==1?'top-activated tabcolor':''">
				店员角色
			</div>
		</div>
	</div>

	<ion-content class="has-subheader bg">
		<ion-refresher pulling-text="下拉刷新..." on-refresh="doRefresh()"></ion-refresher>
		<ion-slide-box delegate-handle="tab-handle" on-touch="onTouch()" on-release="onRelease()" on-slide-changed="slideChanged(index)" active-slide="slideIndex" show-pager="false">
			<ion-slide data-authname="店员管理" data-type="slide" rights-ctrl calss="bg">
				<div class="item nolist text-center" ng-if="list.member.length==0||list.member==null">
					<img src="./img/guilin/other/noorder@2x.png"/>
					<p class="textone">还没有店员数据</p>
					<p class="texttwo">快去添加吧！</p>
				</div>
				<div class="list margin-bottom-10" ng-repeat="n in list.member">
					<div class="item clerkframe">
						<img src="./img/guilin/other/icon_buyer@2x.png" />
						<span class="clerkidtext">{{n.mobile}}</span>
						<span class="roletext">{{n.part_name}}</span>
					</div>
					<div class="item bntframe">
						<div class="btns rebuildbtn" on-tap="openModal_tag(n.member_id,n.part_id)"> 重设角色</div>
						<div class="btns delbtn" on-tap="deletepart(n.member_id, $index)"> 删除店员</div>
					</div>
				</div>	
			</ion-slide>

			<ion-slide data-authname="角色管理" data-type="slide" rights-ctrl>
				<div class="item nolist text-center" ng-if="part_list.length==0||part_list==null">
					<img src="./img/guilin/other/noorder@2x.png"/>
					<p class="textone">还没有角色数据</p>
					<p class="texttwo">快去添加吧！</p>
				</div>				
				<div class="list margin-0" ng-repeat="part in part_list">
				<div class="item bntframe roleframe">
					<span class="roletext">{{part.name}}</span>
						<div class="btns rebuildbtn" on-tap="onshow_addemployee(part.id)">编辑</div>
						<div class="btns delbtn" on-tap="deletepart_right({{part.id}})"> 删除</div>
					</div>
				</div>
			</ion-slide>

		</ion-slide-box>
		<!--加载-->
		<ion-infinite-scroll ng-if="!isLoad" immediate-check="false" on-infinite="doRefreshMore()" distance="1%"></ion-infinite-scroll>
	</ion-content>
	
	<div class="bar bar-footer">
		<div class="addclerk" on-tap="onshow_addemployee()">{{addbtn}}</div>
	</div>
</ion-view>